﻿#region Imports
using System;
using System.Globalization;
using System.Windows.Data;
#endregion

namespace LinqDemo.Converters
{
    public class TopBottomConverter : IValueConverter
    {
        #region Methods
        public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
        {
            switch ((bool?)value)
            {
                case true:
                    return "Top";
                default:
                    return "Bottom";
            }
        }

        public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
        {
            throw new NotImplementedException();
        }
        #endregion
    }
}
